import request from '@/utils/request'

//发送邮箱验证码
export function sendCaptcha(email) {
  return request({
    url: '/api/captcha/sendCaptcha',
    method: 'get',
    params: { email: encodeURIComponent(email) }
  })
}

// 手机号登录
export function phoneLogin(data) {
  return request({
    url: '/api/user-account/login',
    method: 'post',
    data: data
  })
}

//邮箱登录
export function emailLogin(data) {
  return request({
    url: '/api/user-account/login',
    method: 'post',
    data: data
  })
}

//重置密码
export function resetPassword(data) {
  return request({
    url: '/user-account/reset-password',
    method: 'post',
    data: data
  })
}